package com.yj.springbootaop.rest;

import com.yj.springbootaop.anno.Log;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {




    @GetMapping("/test")
    @Log("测试")
    public String test(){

        return "success";
    }

    @GetMapping("/testParams/{id}")
    @Log("携带参数")
    public String testParams(@PathVariable Integer id){

        return "testParams " + id;
    }
}
